The present invention is directed to a multiprocessor system composed of a number of interconnected, individual processor units. More specifically, the present invention provides a method, and teaches apparatus for implementing that method, of maintaining each of the system clocks of each processor unit in synchronization with one another.
Data processing systems often produce data or values that are "time-stamped" when stored; that is, the time (and date) of creation, modification, or storing of the data or value will accompany the data or value for later use. Multiprocessor systems of the type to which the present invention is directed often maintain the fiction of a "system clock," i.e., a single clock accessible to each processor unit of the system, so that any time-stamped actions or values will chronologically correspond to the time-stamped values or actions of other processor units. By providing each of the individual processor units that make up the system with its own clock, and keeping each processor clock synchronized with those of the other processor units, transactions processed by the system, or more particularly the individual processor units, can then be time-stamped (i.e., given a real time indication) by the processor unit, thereby providing an indication of when a particular transaction has been processed relative to other transactions (processed by that or other processor units). For example, multiprocessor systems have been used in the implementation of a number of networked automated teller machines in which large numbers of banking transactions (withdrawals, deposits, etc.) are made in short periods of time. The fictionalized "system clock" is used by each processor unit to provide a notation of the time and date of transaction occurrence.
It will be apparent that in these "transaction processing" environments, it is important that the system clocks of the individual processor units be coordinated or synchronized to one another, sometimes to within milliseconds. For example, the New York Stock Exchange utilizes multiprocessor systems for recording Stock Exchange transactions. It can be critical, therefore, that the transactions be accurately recorded in time in order to preserve transactional priority.
Any synchronization scheme for a multiprocessor system must ensure that the individual processor clocks be monotonically increasing. Were it otherwise, the system clock concept, for accuracy, would not be useful for measuring time between transactions or events, nor would their time stamps be useful as unique identifiers. If a clock jumped backwards, one might obtain the same time stamp more than once.
One previously used technique was to synchronize all clocks to the fastest processor clock in the system. This has the advantage of ensuring that no clock will ever be adjusted backwards. However, the disadvantage of this technique is that, even if crystal-controlled, the individual processor clocks are not perfect; there is a variation among crystals due to manufacturing tolerances. Synchronizing to the fastest processor clock in the system can result in an unacceptable accelerating of system time.
An alternative solution is to maintain, in hardware, a single clock system accessible by each of the multiprocessor units. This, unfortunately, has the disadvantage of instilling a certain amount of vulnerability for fault. If access to the clock is via some form of communication bus used by all processor units, this technique will tend to increase bus traffic, to the exclusion of other necessary interprocessor messaging.